home *** CD-ROM | disk | FTP | other *** search
/ MacHack 1997 / MacHack 1997.toast / Presentations / Presentations ’96 / Sessions ’96 / MacOS 8 Sessions / MacOS 8 Extensions / Demo Patch Code / ShowMMResultsMain.c < prev   
Encoding:
C/C++ Source or Header  |  1996-06-13  |  489 b   |  26 lines  |  [TEXT/CWIE]

  1. #include <stdlib.h>
  2. #include <string.h>
  3. #include <stdio.h>
  4. #include "MMSharedData.h"
  5.  
  6. void main(void);
  7.  
  8. void main(void)
  9. {
  10.     unsigned long            lp;
  11.  
  12.     for (lp=0;lp<NUMAPPS;lp++)
  13.     {
  14.         if (gMMAppList[lp].appName[0])
  15.         {
  16.             char            cappname[32];
  17.  
  18.             memcpy(cappname,&(gMMAppList[lp].appName[1]),gMMAppList[lp].appName[0]);
  19.             cappname[gMMAppList[lp].appName[0]] = 0;
  20.  
  21.             printf("App #%lu, name %s needed %lu blocks of master pointers\n",
  22.                    lp+1,cappname,gMMAppList[lp].appMMCount);
  23.         }
  24.     }
  25. }
  26.